CryptoPro XMLDsig API.
Public API.

ru.CryptoPro.JCPxml.dsig.internal.dom
Class DOMRetrievalMethod

java.lang.Object
  extended by ru.CryptoPro.JCPxml.dsig.internal.dom.DOMStructure
      extended by ru.CryptoPro.JCPxml.dsig.internal.dom.DOMRetrievalMethod
All Implemented Interfaces:
javax.xml.crypto.dom.DOMURIReference, javax.xml.crypto.dsig.keyinfo.RetrievalMethod, javax.xml.crypto.URIReference, javax.xml.crypto.XMLStructure

public final class DOMRetrievalMethod
extends DOMStructure
implements javax.xml.crypto.dsig.keyinfo.RetrievalMethod, javax.xml.crypto.dom.DOMURIReference

DOM-based implementation of RetrievalMethod.


Constructor Summary
DOMRetrievalMethod(org.w3c.dom.Element rmElem, javax.xml.crypto.XMLCryptoContext context, java.security.Provider provider)
          Creates a DOMRetrievalMethod from an element.
DOMRetrievalMethod(java.lang.String uri, java.lang.String type, java.util.List<? extends javax.xml.crypto.dsig.Transform> transforms)
          Creates a DOMRetrievalMethod containing the specified URIReference and List of Transforms.
 
Method Summary
 javax.xml.crypto.Data dereference(javax.xml.crypto.XMLCryptoContext context)
           
 javax.xml.crypto.XMLStructure dereferenceAsXMLStructure(javax.xml.crypto.XMLCryptoContext context)
           
 boolean equals(java.lang.Object obj)
           
 org.w3c.dom.Node getHere()
           
 java.util.List getTransforms()
           
 java.lang.String getType()
           
 java.lang.String getURI()
           
 void marshal(org.w3c.dom.Node parent, java.lang.String dsPrefix, javax.xml.crypto.dom.DOMCryptoContext context)
           
 
Methods inherited from class ru.CryptoPro.JCPxml.dsig.internal.dom.DOMStructure
isFeatureSupported
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.xml.crypto.XMLStructure
isFeatureSupported
 

Constructor Detail

DOMRetrievalMethod

public DOMRetrievalMethod(java.lang.String uri,
                          java.lang.String type,
                          java.util.List<? extends javax.xml.crypto.dsig.Transform> transforms)
Creates a DOMRetrievalMethod containing the specified URIReference and List of Transforms.

Parameters:
uri - the URI
type - the type
transforms - a list of Transforms. The list is defensively copied to prevent subsequent modification. May be null or empty.
Throws:
java.lang.IllegalArgumentException - if the format of uri is invalid, as specified by Reference's URI attribute in the W3C specification for XML-Signature Syntax and Processing
java.lang.NullPointerException - if uriReference is null
java.lang.ClassCastException - if transforms contains any entries that are not of type Transform

DOMRetrievalMethod

public DOMRetrievalMethod(org.w3c.dom.Element rmElem,
                          javax.xml.crypto.XMLCryptoContext context,
                          java.security.Provider provider)
                   throws javax.xml.crypto.MarshalException
Creates a DOMRetrievalMethod from an element.

Parameters:
rmElem - a RetrievalMethod element
Throws:
javax.xml.crypto.MarshalException
Method Detail

getURI

public java.lang.String getURI()
Specified by:
getURI in interface javax.xml.crypto.dsig.keyinfo.RetrievalMethod
Specified by:
getURI in interface javax.xml.crypto.URIReference

getType

public java.lang.String getType()
Specified by:
getType in interface javax.xml.crypto.URIReference

getTransforms

public java.util.List getTransforms()
Specified by:
getTransforms in interface javax.xml.crypto.dsig.keyinfo.RetrievalMethod

marshal

public void marshal(org.w3c.dom.Node parent,
                    java.lang.String dsPrefix,
                    javax.xml.crypto.dom.DOMCryptoContext context)
             throws javax.xml.crypto.MarshalException
Specified by:
marshal in class DOMStructure
Throws:
javax.xml.crypto.MarshalException

getHere

public org.w3c.dom.Node getHere()
Specified by:
getHere in interface javax.xml.crypto.dom.DOMURIReference

dereference

public javax.xml.crypto.Data dereference(javax.xml.crypto.XMLCryptoContext context)
                                  throws javax.xml.crypto.URIReferenceException
Specified by:
dereference in interface javax.xml.crypto.dsig.keyinfo.RetrievalMethod
Throws:
javax.xml.crypto.URIReferenceException

dereferenceAsXMLStructure

public javax.xml.crypto.XMLStructure dereferenceAsXMLStructure(javax.xml.crypto.XMLCryptoContext context)
                                                        throws javax.xml.crypto.URIReferenceException
Throws:
javax.xml.crypto.URIReferenceException

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

Copyright Crypto-Pro.
All rights reserved.